#define _CRT_SECURE_NO_WARNINGS 1
#include<list>
#include "list.h"

int main()
{
	my_std::list<int> p;
	p.push_back(1);
	p.push_back(1);
	p.push_back(1);
	p.push_back(7);
	
	p.push_front(2);
	p.push_front(2);
	p.push_front(2);
	p.push_front(2);
	p.push_front(2);
	p.push_front(2);
	p.push_back(0);
	p.push_front(1);
	p.push_front(1);
	for (auto e : p)
	{
		cout << e << " ";
	}
	cout << endl;
	my_std::list<int> p1;;
	p.pop_back();
	p.pop_front();

	p1 = p;
	//p.push_front(1);

	for (auto e : p)
	{
		cout << e << " ";
	}
	cout <<endl;
	cout <<p.size()<< endl;
	p1.push_front(2);
	p1.push_back(9);
	auto it = p1.rbegin();
	while (it != p1.rend())
	{
		cout << *it << " ";
		it++;
	}
	cout << endl;
	cout << p1.size() << endl;
	return 0;
}